dash: sharechain CoinParams SSOT + oracle-conformance pins (S6) - #146
Merged
Conversation
Add src/impl/dash/config_pool.hpp: the oracle-sourced single source of truth for DASH p2pool sharechain framing constants (PREFIX/IDENTIFIER/SHARE_PERIOD/ CHAIN_LENGTH/TARGET_LOOKBEHIND/SPREAD/P2P_PORT/WORKER_PORT/MIN_PROTOCOL/ MAX_TARGET), transcribed from the DASH-own older-than-v35 oracle frstrtr/p2pool-dash (networks/dash.py + dash_testnet.py). Every other coin (ltc/dgb/bch) already has this; dash share_check/coinbase_builder took an unpopulated core::CoinParams. PREFIX/IDENTIFIER documented as isolation primitives (per-coin+per-instance, never unified). Pin both mainnet+testnet against an independent oracle transcription in test_dash_conformance (DashConformanceNetworkParams, +2 tests). Node-free. Factory wiring (dash::make_coin_params consuming this SSOT) + Fileconfig/ pool.yaml runtime override are the S6 follow-on, deliberately out of scope.
Wire dash::make_coin_params(testnet) so share_check/coinbase_builder consume a CoinParams populated from the config_pool.hpp sharechain SSOT (PR #146) plus oracle-sourced coin-level fields, closing the gap where a const core::CoinParams& consumer could run on an unpopulated/drifted struct. Pool-level fields route through dash::PoolConfig; coin-level (X11 pow+block-identity, P2PKH-only donation, share-version 16, no segwit, DASH address versions) inlined with oracle citations. Node-free half of S6 — complementary to the real-node KAT capture. Adds 4 DashConformanceFactory tests (factory<->SSOT, coin-vs-oracle, donation-all-versions, both-hashes-X11). Linux x86_64 ctest 29/29 green.
Add dash::PoolOverrides + a make_coin_params(testnet, overrides) overload so an operator pool.yaml can retune ONLY non-consensus, non-isolation pool fields (p2p_port / worker_port / bootstrap_addrs). Consensus-critical fields (share version, max_target, donation, X11 pow/block identity) and the network isolation primitives (prefix/identifier) are deliberately absent from the override struct -> never reachable, so a mis-edited pool.yaml can retune ports/peers but can never fork the sharechain off its oracle-conformant identity. The no-arg overload delegates to an empty override set (pure SSOT). Consume-side of the Fileconfig/pool.yaml integration; the YAML file-load half lands when DASH gains its config_pool.cpp Fileconfig (mirrors dgb/btc), so this header carries no file IO. Node-free. Adds 3 DashConformanceFactory override tests (no-override==SSOT, tunables apply, consensus/isolation never touched). Linux x86_64 ctest 32/32 green.
frstrtr
marked this pull request as ready for review
June 18, 2026 11:11
frstrtr
added a commit
that referenced
this pull request
Jun 18, 2026
…ded-body lane — non-destructive, BCH-only ahead
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
S6 node-free slice. Adds the DASH sharechain CoinParams SSOT that every other coin (ltc/dgb/bch) already has; dash share_check/coinbase_builder previously took an unpopulated core::CoinParams.
What
src/impl/dash/config_pool.hpp: oracle-sourced SSOT for PREFIX/IDENTIFIER/SHARE_PERIOD/CHAIN_LENGTH/TARGET_LOOKBEHIND/SPREAD/P2P_PORT/WORKER_PORT/MIN_PROTOCOL/MAX_TARGET, transcribed from DASH-own older-than-v35 oracle frstrtr/p2pool-dash (networks/dash.py + dash_testnet.py).test_dash_conformance: +2 tests (DashConformanceNetworkParams mainnet+testnet) pinning the SSOT against an INDEPENDENT oracle transcription (anti-circular, matching the existing merkle/payout KAT design).Conformance (mainnet): PREFIX 3b3e1286f446b891, IDENTIFIER 7242ef345e1bed6b, SHARE_PERIOD 20, CHAIN_LENGTH 4320, LOOKBEHIND 100, SPREAD 10, P2P 8999, MIN_PROTO 1700, MAX_TARGET 0xFFFF*2^208.
Evidence: Linux x86_64 incremental build clean;
ctest -R DashConformance= 25/25 passed (was 23, +2). Real count, not CWD-hollow.PREFIX/IDENTIFIER documented as isolation primitives (per-coin+per-instance, never unified — operator v36_standardization_goal 2026-06-17).
Out of scope (S6 follow-on): factory wiring (dash::make_coin_params consuming this SSOT) + Fileconfig/pool.yaml runtime override; real-node KAT capture (blocked VM200/201 down).